package cn.wolfcode.wolf2w.repository;


import cn.wolfcode.wolf2w.domain.Region;
import cn.wolfcode.wolf2w.domain.Travel;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 游记持久层接口
 */
@Repository
public interface TravelRepository extends MongoRepository<Travel, String>{

    //点击量前三的游记
    List<Travel> findByDestId(String destId, Pageable pageable);
    //根据目的地名
    List<Travel> findByDestName(String destname);
}
